<template>
  <el-form ref="shiftForm" :model="shift" label-width="150px" label-position="right">
    <el-form-item label="班次编号">
      <el-input v-model="props.data.shiftId" disabled></el-input>
    </el-form-item>
    <el-form-item label="收银员编号">
      <el-input v-model="props.data.employeeId" disabled></el-input>
    </el-form-item>
    <el-form-item label="班次开始时间">
      <el-date-picker
        v-model="props.data.startTime"
        type="datetime"
        disabled
        placeholder="选择日期时间"
      ></el-date-picker>
    </el-form-item>
    <el-form-item label="班次结束时间">
      <el-date-picker
        v-model="props.data.endTime"
        disabled
        type="datetime"
        placeholder="选择日期时间"
      ></el-date-picker>
    </el-form-item>
    <el-form-item label="收银机编号">
      <el-input v-model="props.data.register" disabled></el-input>
    </el-form-item>
    <el-form-item label="交易笔数">
      <el-input v-model.number="props.data.numberOfTransactions" disabled></el-input>
    </el-form-item>
    <el-form-item label="收款总额">
      <el-input v-model="props.data.totalAmount" disabled></el-input>
    </el-form-item>
    <el-form-item label="备注">
      <el-input type="textarea" v-model="props.data.remark" disabled></el-input>
    </el-form-item>
  </el-form>
</template>

<script setup>
import { onMounted } from "vue";

const props = defineProps({
  data: {
    type: Object,
    default: () => ({}),
    required: true,
  },
});

onMounted(() => {
  console.log(props.data);
});
</script>

<style scoped>
.shift-detail {
  width: 80%;
  margin: 20px auto;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
</style>
